package com.yesun.task.pipeline.common;

import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.stereotype.Component;

@Component
@ConfigurationProperties(prefix = "task-pipeline", ignoreUnknownFields = true) //支持静态变量赋值，@Value只支持
public class Config {

    //通过配置赋值，通过这种方式赋值给静态变量
    public void setBasePath(String basePath) {
        System.out.println("设置BASE_PATH：" + basePath);
        Constant.BASE_PATH = basePath;
    }


}
